- ActivitySourceIO
- Source
- ActivitySourceIO (ActivitySource source)
- StartActivity (string name, ActivityKind kind)
- StartActivity ( string name, ActivityKind kind, ActivityContext parentContext, HashMap<string,object> tags = default, Seq<ActivityLink> links = default, DateTimeOffset startTime = default)
- StartActivity ( string name, ActivityKind kind, string parentId, HashMap<string,object> tags = default, Seq<ActivityLink> links = default, DateTimeOffset startTime = default)
- RuntimeEnv ( ActivityEnv Activity, CancellationTokenSource Source, CancellationToken Token, Encoding Encoding)
- Runtime
- Env
- New ()
- New (ActivityEnv activity, CancellationTokenSource source)
- New (ActivityEnv activity, Encoding encoding)
- New (ActivityEnv activity, Encoding encoding, CancellationTokenSource source)
- LocalCancel
- CancellationToken
- CancellationTokenSource
- Encoding
- SetActivity (Activity? activity)
- CurrentActivity
- ActivitySourceEff
- ConsoleEff
- FileEff
- DirectoryEff
- TextReadEff
- TimeEff
- EnvironmentEff
struct ActivitySourceIO Source #
constructor ActivitySourceIO (ActivitySource source) Source #
method Activity? StartActivity (string name, ActivityKind kind) Source #
Creates a new activity if there are active listeners for it, using the specified name and activity kind.
param | name | The operation name of the activity. |
param | kind | The activity kind. |
returns | The created activity object, if it had active listeners, or |
method Activity? StartActivity ( string name, ActivityKind kind, ActivityContext parentContext, HashMap<string,object> tags = default, Seq<ActivityLink> links = default, DateTimeOffset startTime = default) Source #
Creates a new activity if there are active listeners for it, using the specified name, activity kind, parent activity context, tags, optional activity link and optional start time.
param | name | The operation name of the activity. |
param | kind | The activity kind. |
param | parentContext | The parent |
param | tags | The optional tags list to initialise the created activity object with. |
param | links | The optional |
param | startTime | The optional start timestamp to set on the created activity object. |
returns | The created activity object, if it had active listeners, or null if it has no event listeners. |
method Activity? StartActivity ( string name, ActivityKind kind, string parentId, HashMap<string,object> tags = default, Seq<ActivityLink> links = default, DateTimeOffset startTime = default) Source #
Creates a new activity if there are active listeners for it, using the specified name, activity kind, parent activity context, tags, optional activity link and optional start time.
param | name | The operation name of the activity. |
param | kind | The activity kind. |
param | parentId | The parent Id to initialize the created activity object with. |
param | tags | The optional tags list to initialise the created activity object with. |
param | links | The optional |
param | startTime | The optional start timestamp to set on the created activity object. |
returns | The created activity object, if it had active listeners, or null if it has no event listeners. |
record RuntimeEnv ( ActivityEnv Activity, CancellationTokenSource Source, CancellationToken Token, Encoding Encoding) Source #
constructor RuntimeEnv (ActivityEnv activity, CancellationTokenSource source, Encoding encoding) Source #
Live IO runtime
property Runtime LocalCancel Source #
Create a new Runtime with a fresh cancellation token
Used by localCancel to create new cancellation context for its sub-environment
returns | New runtime |
property CancellationToken CancellationToken Source #
Direct access to cancellation token
property CancellationTokenSource CancellationTokenSource Source #
Directly access the cancellation token source
returns | CancellationTokenSource |
property Activity? CurrentActivity Source #
Get the current activity
property Eff<Runtime, LanguageExt.SysX.Traits.ActivitySourceIO> ActivitySourceEff Source #
Activity source environment
returns | Operating-system environment environment |
property Eff<Runtime, ConsoleIO> ConsoleEff Source #
Access the console environment
returns | Console environment |
property Eff<Runtime, DirectoryIO> DirectoryEff Source #
Access the directory environment
returns | Directory environment |
property Eff<Runtime, TextReadIO> TextReadEff Source #
Access the TextReader environment
returns | TextReader environment |
property Eff<Runtime, EnvironmentIO> EnvironmentEff Source #
Access the operating-system environment
returns | Operating-system environment environment |
method Runtime New (ActivityEnv activity, CancellationTokenSource source) Source #
Constructor function
param | activity | Tracing activity |
param | source | Cancellation token source |
method Runtime New (ActivityEnv activity, Encoding encoding) Source #
Constructor function
param | activity | Tracing activity |
param | encoding | Text encoding |
method Runtime New (ActivityEnv activity, Encoding encoding, CancellationTokenSource source) Source #
Constructor function
param | activity | Tracing activity |
param | encoding | Text encoding |
param | source | Cancellation token source |
method Runtime SetActivity (Activity? activity) Source #
Set the current activity and update the ParentId automatically
param | activity | Activity to set |
returns | Updated runtime |